<div class="modal-header bg-primary" >
  <button type="button" class="close" ng-click="cancel()">×</button>
  <i class="fa fa-inbox"></i><span class="label label-tag">审核知识库</span>
</div>
<div class="modal-body">
  <tabset class="tabbable">
      <!-- <tab heading="编辑知识库">

        <div class="row form-group" id="reviewBtns">
         <label class="col-md-2 control-label" ></label>
         <div class="col-md-4"></div>   
       </div>
       <div class="row form-group">
        <label class="col-md-2 control-label" for="title">
          标题:
        </label>
        <div class="col-md-4">
          <input id="title" name="title" class="form-control"  ng-model="entity.title" placeholder="标题" />
        </div>
        <label class="col-md-2 control-label" for="keys">关键字:</label>
        <div class="col-md-4">
         <input  class="form-control" id="keys" ng-model="entity.keys" name="keys"  placeholder="关键字" />
       </div> 
     </div>
     <div class="row form-group">
       <label class="col-md-2 control-label" for="type">分类:</label>
       <div class="col-md-4">
        <input  id="type1" name="type1" ng-model="entity.typeName" class="form-control"  placeholder="分类"
        ng-click="doOnLoad1('type1');" data-toggle="modal" data-target="#typeboxbox"
        > 
        <input type="hidden" id="type1id" name="type1Id" ng-model="entity.type">  
      </div>

      <label class="col-md-2 control-label" for="range">使用范围:</label>
      <div class="col-md-4">
        <select  id="range" class="form-control"  
        ng-model="entity.range"  data-placeholder="选择使用范围">
        <option ng-repeat="r in ranges" value="{{r.id}}">{{r.name}}</option>
      </select>   
    </div> 
  </div>
  <div class="row form-group">
    <label class="col-md-3 control-label" for="number">知识库编号:</label>
    <div class="col-md-8" style="z-indx:1px;">
      <input  id="number" name="number"  ng-model="entity.number" class="form-control"  placeholder="知识库编号"> 
    </div>             
  </div>
  <div class="row form-group">
    <label class="col-md-3 control-label" for="content">知识库内容:</label>
    <div class="col-md-8" style="z-indx:1px;">
      <textarea ckeditor ng-model="entity.content" class="form-control"></textarea>
    </div>             
  </div>
  <div class="row form-group" ng-class="{'has-error': showError('file')}">
    <div class="col-md-2">
      <div class="checkbox clip-check check-primary checkbox-inline">
        <input type="checkbox" id="checkbox10" ng-model="hasAttachment">
        <label for="checkbox10">
          <span class="lbl"  style="margin-left:12px">附件</span>
          <a  href="http://{{path}}/services/solution/download/{{entity.id}}">
            <img src="{{entity.filePic}}" >
          </a>
          {{entity.fileName}}
        </label>
      </div> 
    </div>
    <div class="col-md-9" ng-if="hasAttachment">
      <span class="dz-text-small">提示：上传txt文档以及Office文档不能超过10M,其他文档不能超过200M</span>
      <div class="panel panel-white">
        <div class="panel-body">
          <div class="row">

            <div class="col-md-6">
              <span class="btn btn-primary btn-o btn-file"> 上传文件
                <input name="uploadedFile" type="file" nv-file-select="" uploader="uploader" />
              </span>
            </div>
          </div>
          <div class="row">
            <div ng-repeat="item in uploader.queue">
              <span class="dz-text-small"> 上传的文件: <strong>{{item.file.name }}</strong> </span>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
  

  <input type="hidden" ng-model="entity.id">
  <div class="panel-footer text-center">
   <a ng-click="updateSolution();"  data-dismiss="modal" class="btn btn-primary">提交</a>
   <a data-dismiss="modal" class="btn btn-primary">取消</a>
 </div>
</tab> -->

    <tab heading="审核" ng-if="shenhe" >
            
      <div class="row form-group" id="reviewBtns" >
        <label class="col-md-3 control-label" >请审核该知识信息</label>
        <div class="col-xs-6 col-md-6">              
          <div class="panel-body">
            <div class="radio clip-radio radio-primary radio-inline">
              <input type="radio" id="radio1" name="name" ng-model="verifyType" value="success"  ng-checked=" ">
              <label for="radio1">通过 </label>
            </div>
            <div class="radio clip-radio radio-primary radio-inline">
              <input type="radio" name="name" ng-model="verifyType" id="radio2"   value="failed" >
              <label for="radio2">驳回 </label>
            </div>
            <div class="radio clip-radio radio-primary radio-inline">
              <input type="radio" id="radio3" name="name" ng-model="verifyType" value= "reject">
              <label for="radio3">拒绝 </label>
            </div>
          </div>
        </div> 
      </div>   
      <div class="row form-group"  ng-show="verifyType=='failed'||verifyType=='reject'"> 
        <label class="col-md-2 control-label" for="reason">意见</label> 
        <div class="col-md-8">
          <textarea  id="reasonval" ng-model="reason" class="form-control"></textarea>
        </div> 
      </div>   
      <input type="hidden" ng-model="entity.id">
      <div class="row form-group" ng-if="shouquan" ng-show="verifyType=='success'">
      <label for="actionTypes" class="col-xs-6 control-label">请选择权限组</label>
        <div class="col-md-8">
          <div class="form-group">
            
            <ui-select multiple ng-model="multipleDemo.item" theme="bootstrap" ng-disabled="disabled" close-on-select="false">
              <ui-select-match placeholder="选择权限组...">{{$item.groupname}}</ui-select-match>
              <ui-select-choices repeat="tata in group">{{tata.groupname}}</ui-select-choices>
            </ui-select>
          </div>
        </div>
      
      
       </div>
      <div class="panel-footer text-center">
        <a ng-click="saveright(multipleDemo);verifySolutions(verifyType,reason); " ng-hide="entity.verifyType"  data-dismiss="modal" class="btn btn-primary">提交</a>
        <button class="btn btn-primary btn-o" ng-click="cancel()" translate="modal.button.CANCEL">取消</button>
      </div> 
    </tab>

    <tab heading="发布" ng-if="fabu">
        
      <div class="row form-group" id="reviewBtns">
        <label class="col-md-3 control-label" ng-if="fabulabel">请发布该知识信息</label>
         
        <div class="col-xs-6 col-md-6">
          
          <div ng-show="!showOutTime" style="float:right;"> 
            <button type="button" class="btn btn-info" ng-click="verifySolutions('publish'); " ng-show="entity.outtime" ng-if="fabulabel">发布</button>
             
          </div>
          <div  style="float:right;" ng-show="couldReview"></div> 
        </div>   
      </div>
     <!--  <div class="row form-group" ng-show="showReason"> 
        <label class="col-md-2 control-label" for="reasons">{{reasonName}}意见</label> 
        <div class="col-md-8">
          <textarea ckeditor id="reasonval" ng-model="reason" class="form-control"></textarea>
        </div> 
      </div>   
      <input type="hidden" ng-model="entity.id"> -->
    </tab>
    <tab heading="撤销" ng-if="chexiao">
      <div class="row form-group" id="reviewBtns">
        <label class="col-md-3 control-label" ng-if="chexiao">确定撤销该知识吗？</label>
        <div class="col-xs-6 col-md-6">
         <!--  <div  style="text-align: center;" ng-show="chexiao" >
               <p class="margin-bottom-10">
                 确定撤销该知识吗？
                </p>
                <p>
                  <a ng-click="ok()" class="btn btn-danger">
                    确定
                  </a>
                  <a ng-click="cancle()" class="btn btn-o btn-danger">
                    取消
                  </a>
                </p>
              </div> -->
          <div ng-show="!showOutTime" style="float:right;"> 
            <button type="button" class="btn btn-default" ng-click="verifySolutions('outtime');"  ng-if="chexiao" >确定</button>
            <button type="button" class="btn btn-default" ng-click="cancel()"  ng-if="chexiao" >取消</button>
          </div>
          <div  style="float:right;" ng-show="couldReview"></div> 
        </div>   
      </div>
      <!-- <div class="row form-group" ng-show="showReason"> 
        <label class="col-md-2 control-label" for="reasons">{{reasonName}}意见</label> 
        <div class="col-md-8">
          <textarea ckeditor id="reasonval" ng-model="reason" class="form-control"></textarea>
        </div> 
      </div>  -->  
      <!-- <input type="hidden" ng-model="entity.id"> -->
    </tab>
      <!-- 授权start -->
    <!-- <tab heading="授权" ng-if="shouquan" >
      <div class="row form-group">
      <label for="actionTypes" class="col-xs-6 control-label">请选择权限组</label>
        <div class="col-md-8">
          <div class="form-group">
            
            <ui-select multiple ng-model="multipleDemo.item" theme="bootstrap" ng-disabled="disabled" close-on-select="false">
              <ui-select-match placeholder="选择权限组...">{{$item.groupname}}</ui-select-match>
              <ui-select-choices repeat="tata in group">{{tata.groupname}}</ui-select-choices>
            </ui-select>
          </div>
        </div>
      
      
       </div>
      <div class="panel-footer text-center">
 
       <a ng-click="verifySolutions(verifyType,reason);saveright(multipleDemo);cancel();" data-dismiss="modal" class="btn btn-primary">提交</a>
        <button class="btn btn-primary btn-o" ng-click="cancel()" translate="modal.button.CANCEL">取消</button>
          </div> 
    </tab> -->

      <!-- <tab ng-repeat="tab in tabs" heading="{{tab.title}}" active="tab.active" disabled="tab.disabled">
        {{tab.content}}
      </tab>
      <tab select="alertMe()">
        <tab-heading>
          <i class="glyphicon glyphicon-bell"></i> Alert!
        </tab-heading>
        I've got an HTML heading, and a select callback. Pretty cool!
      </tab> -->
  </tabset>
</div>
<div class="modal-footer">
  
</div>

<!--审核知识库 start-->
    <div id="reviewKnowledge" class="modal fade modal-blur" tabindex="-1" role="dialog" style="display:none;" >
          <div class="modal-dialog">
                <div class="modal-content panel-info" style="width:800px;">
                   <div class="modal-header panel-heading">
                      <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                      <h4 class="modal-title"><i class="fa  fa-gears"></i>审核知识库</h4>
                  </div>
                  <div class="modal-body" >
                     <ul id="uidemo-tabs-default-demo" class="nav nav-tabs" style="margin-top: 20px">
                          <li ng-repeat="tab in reviewKnowledge.tabs" ng-class="tab.active">
                          <a  data-toggle="tab"  ng-click="reviewKnowledge.tabselect(tab.id);">{{tab.title}}</a>
                           </li>
                      </ul>

                      <div class="tab-content tab-content-bordered">  
                      <!--编辑知识库 start-->
                        <div class="tab-pane fade" ng-class="reviewKnowledge.tabs[0].divactive">
                              <div class="row form-group"> 
                                     <label class="col-md-2 control-label">附件
                                        <a  href="http://{{path}}/services/solution/download/{{entity.id}}">
                                          <!-- <img src="{{entity.filePic}}" > -->
                                        </a>
                                      </label>
                                     <div class="col-md-4"> 
                                      <input type="hidden" id="fileNames" ng-model="entity.fileName"  value="{{entity.fileName}}">
                                        {{entity.fileName}}
                                    </div> 
                                     <!--label class="col-md-2 control-label" for="publishRange">发布范围</label> 
                                     <div class="col-md-4">
                                      <select  id="publishRange" class="form-control"  
                                         ng-model="entity.publishRange"  data-placeholder="选择发布范围">
                                                <option ng-repeat="r in publishRanges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                    </div--> 
                            </div>       
                            <div class="row form-group" id="reviewBtns">
                                 <label class="col-md-2 control-label" ></label>
                                 <div class="col-md-4"></div>  
                                    

                                 <!--  <label class="col-md-2 control-label"> 审核： </label> -->
                                  <!--div class="col-xs-6 col-md-6">
                                      <div ng-show="!showOutTime" style="float:right;"> 
                                         <button type="button" class="btn btn-info" ng-click="verifySolution('publish');" ng-show="entity.outtime">发布</button>
                                  
                                        <button type="button" class="btn btn-default" ng-click="verifySolution('outtime');" ng-show="entity.outtime">撤销</button>
                                      </div>
                                      
                                      <div ng-show="showOutTime" style="float:right;">
                                        <button type="button" class="btn btn-info disabled" >发布</button>
                                        <button type="button" class="btn btn-default disabled">撤销</button>
                                      </div>

                                      <div ng-show="couldReview" style="float:right;">
                                          <button type="button" class="btn btn-success" ng-click="verifySolution('success');">通过</button>
                                        
                                          <button type="button" class="btn btn-danger" ng-click="verifySolution('failed');">驳回</button>
                                          <button type="button" class="btn btn-warning" ng-click="verifySolution('reject');">拒绝</button>
                                      </div> 
                                       <div ng-show="!couldReview" style="float:right;">
                                            <button type="button" class="btn btn-success disabled">通过</button>
                                            <button type="button" class="btn btn-danger disabled">驳回</button>
                                            <button type="button" class="btn btn-warning disabled">拒绝</button>
                                       </div>
                                  </div-->   
                             </div>
                            <div class="row form-group">
                                    <label class="col-md-2 control-label" for="title">
                                            标题:
                                    </label>
                                    <div class="col-md-4">
                                        <input id="title" name="title" class="form-control"  ng-model="entity.title" placeholder="标题" />
                                    </div>
                                     <label class="col-md-2 control-label" for="keys">关键字:</label>
                                     <div class="col-md-4">
                                           <input  class="form-control" id="keys" ng-model="entity.keys" name="keys"  placeholder="关键字" />
                                     </div> 
                            </div>
                             <div class="row form-group">
                                 <label class="col-md-2 control-label" for="type">分类:</label>
                                 <div class="col-md-4">
                                      <input  id="type1" name="type1" ng-model="entity.typeName" class="form-control"  placeholder="分类"
                                          ng-click="doOnLoad1('type1');" data-toggle="modal" data-target="#typeboxbox"
                                          > 
                                         <input type="hidden" id="type1id" name="type1Id" ng-model="entity.type">  
                                 </div> 
                                 <label class="col-md-2 control-label" for="range">使用范围:</label>
                                 <div class="col-md-4">
                                      <select  id="range" class="form-control"  
                                         ng-model="entity.range"  data-placeholder="选择使用范围">
                                                <option ng-repeat="r in ranges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                </div> 
                            </div>
                                 
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="number">知识库编号:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                          <input  id="number" name="number"  ng-model="entity.number" class="form-control"  placeholder="知识库编号"> 
                                    </div>             
                            </div>
                            <div class="row form-group">
                                    <label class="col-md-3 control-label" for="content">知识库内容:</label>
                                    <div class="col-md-8" style="z-indx:1px;">
                                      <textarea ckeditor ng-model="entity.content" class="form-control"></textarea>
                                    </div>             
                            </div>
                            <input type="hidden" ng-model="entity.id">
                            <div class="panel-footer text-center">
                                   <a ng-click="updateSolution();"  data-dismiss="modal" class="btn btn-primary">提交</a>
                                  <a  data-dismiss="modal" class="btn btn-primary">取消</a>
                               </div>
                         </div><!--tab-pane fade -->
                        <!--审核页面 start-->

                         <div class="tab-pane fade" ng-class="reviewKnowledge.tabs[1].divactive">
                              <div class="row form-group" ng-show="publishbox"> 
                                     <label class="col-md-2 control-label" for="publishRange">发布范围</label> 
                                     <div class="col-md-4">
                                      <select  id="publishRange" class="form-control"  
                                         ng-model="entity.publishRange"  data-placeholder="选择发布范围">
                                                <option ng-repeat="r in publishRanges" value="{{r.id}}">{{r.name}}</option>
                                        </select>   
                                    </div> 
                            </div>       
                            <div class="row form-group" id="reviewBtns">
                                 <label class="col-md-2 control-label" >审核</label>
                                  <div class="col-xs-6 col-md-6">
                                      <div ng-show="!showOutTime" style="float:right;"> 
                                         <button type="button" class="btn btn-info" ng-click="verifySolution('publish');" ng-show="entity.outtime">发布</button>
                                  
                                        <button type="button" class="btn btn-default" ng-click="verifySolution('outtime');" ng-show="entity.outtime">撤销</button>
                                      </div>
                                      
                                      <!--div ng-show="showOutTime" style="float:right;">
                                        <button type="button" class="btn btn-info disabled" >发布</button>
                                        <button type="button" class="btn btn-default disabled">撤销</button>
                                      </div-->

                                      <div  style="float:right;" ng-show="couldReview"> <!---->
                                          <button type="button" class="btn btn-success" ng-click="verifySolution('success');">通过</button>
                                        
                                          <button type="button" class="btn btn-danger" ng-click="verifySolution('failed');">驳回</button>
                                          <button type="button" class="btn btn-warning" ng-click="verifySolution('reject');">拒绝</button>
                                      </div> 
                                       <!--div ng-show="!couldReview" style="float:right;">
                                            <button type="button" class="btn btn-success disabled">通过</button>
                                            <button type="button" class="btn btn-danger disabled">驳回</button>
                                            <button type="button" class="btn btn-warning disabled">拒绝</button>
                                       </div-->
                                  </div>   
                             </div>
                             <div class="row form-group" ng-show="showReason"> 
                                     <label class="col-md-2 control-label" for="reasons">{{reasonName}}意见</label> 
                                     <div class="col-md-8">
                                      <textarea ckeditor id="reasonval" ng-model="reason" class="form-control"></textarea>
                                    </div> 
                            </div>   
                            <input type="hidden" ng-model="entity.id">
                             <div class="panel-footer text-center">
                                   <a ng-click="verifySolutions('{{verifyType}}');"  data-dismiss="modal" class="btn btn-primary">提交</a>
                                  <a  data-dismiss="modal" class="btn btn-primary">取消</a>
                             </div> 
                         </div>
                         <!--审核页面 end -->

                      <!--授权 start -->
                      <div class="tab-pane fade {{reviewKnowledge.tabs[2].divactive}}">  
                               <div class="row form-group">
                                  <div class="col-md-8">
                                    <label for="actionTypes" class="col-xs-3 control-label">权限类型:</label>
                                    <div class="col-xs-8">
                                      <select  id="actions" class="form-control"  
                                         ng-model="actionType"  data-placeholder="权限类型">
                                                <option ng-repeat="r in solutionActionTypes" value="{{r.id}}" ng-selected="{{r.id == 1}}">{{r.name}}</option>
                                        </select>  
                                    </div>
                                  </div>
                                 </div> 

                                
                                 <div class="row form-group"  style="margin-left:15px;">
                                 <div class="col-md-8">
                                      <div id="jsTreeGroups" > 
                                          <div class="row" cg-busy="vm.promise">
                                              <toaster-container></toaster-container>
                                          <div> 
                                          <div class="panel panel-info">
                                             <div class="panel-heading">
                                                  <i class="glyphicon glyphicon-tree-conifer"></i>知识库分类
                                             </div> 
                                             <div class="panel-body">
                                               <div class="box-tree">
                                                  <span ng-if="doing_async">...加载中...</span>
                                                  <abn-tree tree-data="type_data" tree-control="tree1" on-select="type_handler(branch)" icon-leaf="ti-file" icon-expand="ti-plus" icon-collapse="ti-minus"></abn-tree>
                                                </div>
                                             </div>
                                         </div>
                                        </div>
                                       </div>
                                   </div> 
                                 </div>
                                <div class="row form-group"  style="margin-left:15px;">
                                 <div class="col-md-8">
                                      <div id="jsTreeGroups"> 
                                          <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>工作组
                                             </div> 
                                             <div class="panel-body">
                                                <ui-select ng-model="groupIds" theme="bootstrap">
                                                    <ui-select-match placeholder="选择工作组...">
                                                      {{$select.selected.name}}
                                                    </ui-select-match>
                                                    <ui-select-choices repeat="item in groups | filter: $select.search">
                                                      <div ng-bind-html="item.name | highlight: $select.search"></div>
                                                    </ui-select-choices>
                                                  </ui-select>
                                             </div>
                                         </div>
                                        </div>
                                       </div>
                                   </div> 
                                 </div>
                             </div> 
                            <div class="row form-group" >
                                <div  class="col-md-15" style="padding-left:25px;">
                                    <div class="select_side" > 
                                        <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>待选区
                                             </div> 
                                             <div class="panel-body"> 
                                               <select id="selectL" name="selectL"  multiple="multiple"  
                                                        ng-model="selectModelL"  ng-options=" (o.order+'--'+o.name) for o in peopleL | index"  
                                                        ng-change="selChange(selectModelL)">
                                                     <option value=""></option>     
                                               </select>
                                                <div class="sub_btn"><input type="button" class="btn btn-info" id="sub1" value="保存" ng-click="saveSolution()"/></div>  
                                              </div>
                                          </div>
                                   </div> 

                                 <div class="select_side"> 
                                       <div class="panel panel-info">
                                             <div class="panel-heading">
                                                 <i class="glyphicon glyphicon-tree-conifer"></i>已选区
                                             </div> 
                                             <div class="panel-body"> 
                                                 <select id="selectR" name="selectR" multiple="multiple" 
                                                         ng-model="selectModelR" ng-options=" (o.order+'--'+o.name)  for o in peopleR | index"  
                                                          ng-change="selChange(selectModelR)"> 
                                                 </select> 
                                                 <div class="sub_btn"><input type="button" class="btn btn-info"  id="sub2" value="赋予全体用户权限" ng-click="saveAllSolution()"/></div>    
                                            </div> 
                                    </div>
                               </div>
                             </div>
                            </div>
                         
                       </div>
                   <!--授权 end -->

                 </div><!--tab-content-->
              </div><!--content-body-->
            </div>
        </div> 
    </div> 
    <!--审核知识库 end-->   